//
//  SCComposeTitleView.swift
//  weibo
//
//  Created by 阿城 on 15/12/14.
//  Copyright © 2015年 阿城. All rights reserved.
//

import UIKit

class SCComposeTitleView: UIView {

    private lazy var nameLabal:UILabel = {
        let name = SCUserInfoViewModel.shareInfoViewModel.userInfoMod?.screen_name
        let lab = UILabel(titleText: name!, color: UIColor.darkGrayColor(), fontSize: 12)
        return lab
    }()
    private lazy var detailLabel = UILabel(titleText: "发微博", fontSize: 15)
    
    override init(frame: CGRect) {
        super.init(frame: frame)
        setupUI()
    }

    required init?(coder aDecoder: NSCoder) {
        fatalError("init(coder:) has not been implemented")
    }
    
    private func setupUI(){
        addSubview(detailLabel)
        addSubview(nameLabal)
        backgroundColor = UIColor.redColor()
        
        detailLabel.snp_makeConstraints { (make) -> Void in
            make.centerX.equalTo(self)
            make.top.equalTo(self)
        }
        nameLabal.snp_makeConstraints { (make) -> Void in
            make.top.equalTo(detailLabel.snp_bottom)
            make.centerX.equalTo(self)
            make.bottom.equalTo(self)
        }
        height = 40
    }
    
}
